import React from "react";
import "./button.css";
import { css } from "@linaria/core";
import './button.less'
const color = css`
  color: blue;
`;

export interface ButtonProps {
  /** 属性类型定义，属性说明，必填值 */
  text: string;

  /**
   * 非必填，radio选项
   */
  size?: "small" | "medium" | "large";
  /**
   * 边框色
   */
  outlineColor?: string;
}

/**  组件简介，描述组件作用，必须要export */
export const Button = ({
  size = "small", // 默认值设置方式1
  ...props
}: ButtonProps) => {
  return (
    <button
      className={color}
      style={{
        outline: `${props.outlineColor} solid`,
      }}
    >
      {props.text}
    </button>
  );
};

Button.defaultProps = {
  outlineColor: "skyblue", // 默认值设置方式2
};
export default Button;
